also

Adds another test, and potentially another error, to a Validation.

Return

ValidationResult with this stored value, possibly a new error state and new error message

Author

fzzyhmstrs

Since

0.7.0

Parameters

C

Type of error content to store. This is usually a string message

newTest

Boolean result of another validation test

type

ErrorEntry.Type<C> the error type. When in doubt, use Errors.BASIC

builder

UnaryOperator<ErrorEntry.Builder> operator for applying content to a provided error builder.


Adds another test, and potentially another error, to a Validation.

Return

ValidationResult with this stored value, and possibly a new error state and new error message

Author

fzzyhmstrs

Since

0.7.0

Parameters

newTest

Boolean result of another validation test

type

ErrorEntry.Type the string-based error type. When in doubt, use Errors.BASIC

error

The error message

e

Optional Throwable if the error is a critical one


Deprecated

Plain error strings are deprecated but acceptable. Most of the time passing in ErrorContext is preferred

Adds another test, and potentially another error, to a Validation.

Return

ValidationResult with this stored value, possibly a new error state and new error message

Author

fzzyhmstrs

Since

0.2.0, deprecated 0.7.0

Parameters

newTest

Boolean result of another validation test

error

error message if the newTest fails validation